﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Mvc;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel;

namespace TravelWeb.Models
{
    [Bind(Exclude = "DestinationID")]
    public class Destination
    {
        [ScaffoldColumn(false)]
        public int DestinationID { get; set; }
        [Required(ErrorMessage = "Name of place is required")]
        [DisplayName("Destination Name")]
        [StringLength(160)]
        public String DestinationName { get; set; }
        [Required(ErrorMessage = "City is required")]
        [StringLength(40)]
        public String City { get; set; }
        [Required(ErrorMessage = "Address is required")]
        [StringLength(70)]
        public String Address { get; set; }
        [ScaffoldColumn(false)]
        public int? SupplierID { get; set; }

        public Supplier Supplier { get; set; }
        public List<Destination> Destinations { get; set; }
    }
}